<?php
namespace app\backstage\validate;
use think\Validate;

class Agent extends Validate
{
    protected $rule = [
        'status'       => 'require|egt:0',
        'account'      => 'require',
    ];

    protected $message  =   [
        'status.require'          => '请选择激活状态',
        'status.gt'               => '请选择激活状态',
        'account.require'         => '账号名称不能为空',
    ];

    protected $scene = [
        'add'   => ['account','status'],
        'edit'  => ['id','account','status'],
        'info'  => ['id'],
    ];
}